package com.xinyue.authorization.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.xinyue.authorization.bean.Organization;
import com.xinyue.authorization.dao.OrganizationDao;
import com.xinyue.authorization.service.OrganizationService;

@Service
@Transactional
public class OrganizationServiceImpl implements OrganizationService{
	@Autowired
	OrganizationDao dao;

	public void save(Organization entity) {
		dao.save(entity);
	}

	public Integer deleteById(int orgId) {
		return dao.deleteById(orgId);
	}

	public void update(Organization entity) {
		dao.update(entity);
	}

	public Organization queryById(int orgId) {
		return dao.queryById(orgId);
	}

	public List<Organization> queryAll(int begin, int count) {
		return dao.queryAll(begin, count);
	}

	public Integer queryCount() {
		return dao.queryCount();
	}
}